package com.meilai.project.entity.business.contract;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.meilai.project.dto.workflow.FlowBusinessDataSuperEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.time.LocalDate;

/**
 * <p>
 *
 * </p>
 *
 * @author xchen
 * @since 2022-03-04
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("contract_apply")
@ApiModel(value = "ContractApply对象", description = "")
public class ContractApply extends FlowBusinessDataSuperEntity {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("合同编号")
    private String contract_num;

    @ApiModelProperty("客户ID（项目名称）")
    private Long customer_id;

    @ApiModelProperty("甲方")
    private String part_a;

    @ApiModelProperty("乙方id")
    private Long part_b_id;

    @ApiModelProperty("乙方名称")
    private String part_b_name;

    @ApiModelProperty("甲方人联系方式")
    private String part_a_contact;

    @ApiModelProperty("乙方人联系方式")
    private String part_b_contact;

    @ApiModelProperty("开户名")
    private String bank_account_name;

    @ApiModelProperty("开户行名")
    private String bank_name;

    @ApiModelProperty("开户号")
    private String bank_num;

    @ApiModelProperty("合同开始日期")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate contract_begin_date;

    @ApiModelProperty("合同结束日期")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate contract_end_date;

    @ApiModelProperty("签订日期")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate sign_date;


    @ApiModelProperty("优惠价格")
    private BigDecimal discounted_price;

    @ApiModelProperty("优惠价格（大写）")
    private String discounted_price_big;

    //todo new
    @ApiModelProperty("是否含税")
    private Boolean contain_tax;

    //todo new
    @ApiModelProperty("另收**%税费")
    private BigDecimal tax_percent;

    //todo new
    @ApiModelProperty("税费金额")
    private BigDecimal tax;

    @ApiModelProperty("自有资源价格")
    private BigDecimal self_price;

    //todo new
    @ApiModelProperty("自有资源价格（大写）")
    private String self_price_big;

    @ApiModelProperty("代理资源价格")
    private BigDecimal proxy_price;

    //todo new
    @ApiModelProperty("代理资源价格（大写）")
    private String proxy_price_big;

    @ApiModelProperty("画面更换价格")
    private BigDecimal replace_price;

    @ApiModelProperty("画面多次更换价格")
    private BigDecimal multi_replace_price;

    @ApiModelProperty("验收方式")
    private String acceptance_way;

    //todo new
    @ApiModelProperty("现金支付金额")
    private BigDecimal pay_cash_amount;

    //todo new
    @ApiModelProperty("现金支付金额（大写）")
    private String pay_cash_amount_big;

    //todo new
    @ApiModelProperty("置换金额")
    private BigDecimal displace_amount;

    //todo new
    @ApiModelProperty("置换金额（大写）")
    private String displace_amount_big;

    @ApiModelProperty("备注")
    private String memo;

    @ApiModelProperty("备注")
    private String other_memo;

    @ApiModelProperty("父合同ID，补充协议时使用，普通合同不传")
    private Long parent_id;

    @ApiModelProperty("根合同ID，补充协议时使用，普通合同不传")
    private Long root_id;

    @ApiModelProperty("最后催收提醒日期")
    private LocalDate last_collection_reminder_date;
    @ApiModelProperty("最后催款提醒日期")
    private LocalDate last_press_for_money_reminder_date;
    @ApiModelProperty("最后到期提醒日期")
    private LocalDate last_expire_reminder_date;

    @ApiModelProperty("是否收到合同材料 0：否 1：是")
    private Boolean receive_contract;

    @ApiModelProperty("合同入档编号")
    private String contract_filing_no;

    //0:正常，1挂起，2作废
    private Integer mode;

}
